﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication2
{
    class Program
    {
        static void Main(string[] args)
        {
            ConsolePoint cp = new ConsolePoint(5,6);
            Annotation note = new Annotation(3,4);
            Point point = new Point(1,1);
           

            Point p = cp;
            Point n = note;

            Annotation newNote = (Annotation) p;

            Console.WriteLine(newNote.Message);

            ArrayList arrList = new ArrayList();
            arrList.Add(cp);
            arrList.Add(note);
            arrList.Add(1);





        }
    }

    class Point
    {
        public int X { get; set; }
        public int Y { get; set; }

        public Point(int x = 7, int y = 7)
        {
            X = x;
            Y = y;
        }
    }

    class ConsolePoint : Point
    {
        public char DisplayedSymbol { get; set; }

        public ConsolePoint(int x, int y)
            :base(x,y)
        {
            
        }
    }

    class Annotation : Point
    {
        public string Message { get; set; }

        public Annotation(int x, int y)
            :base(x,y)
        {
            Message = "Hello";
        }
    }

}
 